With the rapid development of Internet technologies, a growing number of service providers provide users with geographic location-based services, such as searching for a nearby restaurant or parking lot based on a current location.
In related technologies, when the geographic location-based service is provided, a region that a requesting location belongs to is usually first determined based on a GeoHash algorithm(s), and then a service needed by the user is searched for based on the determined region. However, in the GeoHash algorithm, a latitude and a longitude are encoded through a dichotomic search, and the sizes of the regions with different encoded latitudes are different. Because the size of a low-latitude region is greater than the size of a high-latitude region, considerable processing resources of a server are wasted when processing a service in the low-latitude region.